<template>
	<view class="content">
		<view class="header">
			<view class="header">
				<view :style="{height: systemBarHeight + 'px'}">
				</view>
				<view class="navbar">
					<image src="/static/xy/fh.png" mode="" @click="fh()"></image>
					<text>预 约</text>
				</view>
			</view>
		</view>

		<view class="tabs">
			<u-tabs :list="list4" lineWidth="10" lineColor="#53DDA8" :activeStyle="{
			            color: '#53DDA8',
			            fontWeight: 'bold',
			            transform: 'scale(1.05)'
			        }" :inactiveStyle="{
			            color: '#666666',
			            transform: 'scale(1)'
			        }" :scrollable="fasle" itemStyle="padding-bottom:20rpx;">
			</u-tabs>
		</view>

		<view class="list">
			<view class="list_item" v-for="(item,index) in list5" :key="index">


				<view class="list_item1">
					<view class="list_item1_lf">
						<text>预约编号 | {{item.bh}}</text>
					</view>
					<view class="list_item1_rg">
						<text class="starts1" v-if="item.starts==0">待确认</text>
						<text class="starts2" v-if="item.starts==1">已确认</text>
						<text class="starts2" v-if="item.starts==2">未通过</text>
						<text class="starts2" v-if="item.starts==3">已取消</text>
					</view>
				</view>

				<view class="list_item2">
					<view class="list_item2_lf">
						<text>王教练 | 科目二</text>
					</view>
					<view class="list_item2_rg">
						<text>2号车</text>
					</view>
				</view>
				<view class="list_item3">
					<image src="/static/xy/shijian.png" mode=""></image>
					<text>2025-01-01 10:00 至 2025-01-01 10:00</text>
				</view>

				<view class="list_item4">
					<view class="list_item4_lf">
						<text>2025-01-01 15:00:15</text>
					</view>
					<view class="list_item4_rg">
						<text>取消预约</text>
					</view>
				</view>
			</view>

		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				systemBarHeight: 0,

				list4: [{
					name: '待确认'
				}, {
					name: '已确认',

				}, {
					name: '未通过',
				}, {
					name: '已取消'
				}],

				list5: [{
						bh: '131231231',
						starts: 0,

					},
					{
						bh: '131231231',
						starts: 1,

					},
					{
						bh: '131231231',
						starts: 2,

					},
					{
						bh: '131231231',
						starts: 3,

					}

				]
			}
		},
		mounted() {
			/* 手机顶部高度 */
			this.getSysteminfo()
		},
		methods: {
			/* 手机顶部高度 */
			getSysteminfo() {
				uni.getSystemInfo({
					success: res => {
						this.systemBarHeight = res.statusBarHeight;
					}
				});
			},
			fh() {
				uni.navigateBack({
					delta: 1
				})
			}
		}
	}
</script>

<style lang="scss" scoped>
	.header {
		background: #FFFFFF;
	}

	.navbar {
		height: 88rpx;
		display: flex;
		align-items: center;
		justify-content: center;
		position: relative;

		>image {
			width: 48rpx;
			height: 48rpx;
			position: absolute;
			left: 32rpx;
		}

		>text {

			font-family: PingFang SC, PingFang SC;
			font-weight: 600;
			font-size: 34rpx;
			color: #43484D;

		}
	}

	.list {
		padding-top: 46rpx;

		.list_item {
			width: 93%;
			margin: 0 auto 24rpx;
			height: 350rpx;
			background: linear-gradient(180deg, #EAFFF7 0%, #FFFFFF 100%);
			box-shadow: 0rpx 4rpx 16rpx 0rpx rgba(25, 94, 68, 0.05);
			border-radius: 16rpx 16rpx 16rpx 16rpx;

			.list_item1 {
				margin: auto;
				padding-top: 32rpx;
				width: 90%;
				display: flex;
				align-items: center;
				justify-content: space-between;

				.list_item1_lf {
					font-family: PingFang SC, PingFang SC;
					font-weight: 400;
					font-size: 26rpx;
					color: #5C5C5C;

				}

				.list_item1_rg {

					.starts1 {
						font-family: PingFang SC, PingFang SC;
						font-weight: 400;
						font-size: 26rpx;
						color: #F60000;
					}

					.starts2 {
						font-family: PingFang SC, PingFang SC;
						font-weight: 400;
						font-size: 26rpx;
						color: #43484D;
					}
				}
			}

			.list_item2 {
				margin: 32rpx auto 0;
				width: 90%;
				display: flex;
				align-items: center;
				justify-content: space-between;

				.list_item2_lf {

					font-family: PingFang SC, PingFang SC;
					font-weight: 500;
					font-size: 30rpx;
					color: #43484D;
				}

				.list_item2_rg {
					font-family: PingFang SC, PingFang SC;
					font-weight: 400;
					font-size: 28rpx;
					color: #53DDA8;
				}
			}

			.list_item3 {
				width: 90%;
				margin: 24rpx auto 0;
				height: 56rpx;
				background: #E2FFF4;
				border-radius: 8rpx 8rpx 8rpx 8rpx;
				display: flex;
				justify-content: center;
				align-items: center;

				>image {
					width: 32rpx;
					height: 32rpx;
				}

				>text {
					font-family: PingFang SC, PingFang SC;
					font-weight: 400;
					font-size: 28rpx;
					color: #43484D;
					margin-left: 16rpx;
				}
			}

			.list_item4 {
				width: 90%;
				margin: 32rpx auto 0;
				display: flex;
				align-items: center;
				justify-content: space-between;

				.list_item4_lf {
					font-family: PingFang SC, PingFang SC;
					font-weight: 400;
					font-size: 28rpx;
					color: #43484D;
				}

				.list_item4_rg {
					width: 160rpx;
					height: 64rpx;
					background: #53DDA8;
					border-radius: 8rpx 8rpx 8rpx 8rpx;
					font-family: PingFang SC, PingFang SC;
					font-weight: 400;
					font-size: 28rpx;
					color: #FFFFFF;
					display: flex;
					align-items: center;
					justify-content: center;
				}
			}

		}
	}
</style>